πŸ•ΈοΈ Ada Research Browser

tasks.md
← Back

Tasks: Pre-Baked Vagrant Box Workflow

Input: Design documents from /specs/009-vagrant-prebaked-boxes/ Prerequisites: plan.md (required), spec.md (required), research.md, data-model.md, quickstart.md

Tests: Not explicitly requested. Manual validation via demo scenario playbooks serves as functional test.

Organization: Tasks grouped by user story to enable independent implementation and testing.

Format: [ID] [P?] [Story] Description


Phase 1: Setup (Shared Infrastructure)

Purpose: Create directory structure, update gitignore and Makefile


Phase 2: Foundational (Blocking Prerequisites)

Purpose: Core infrastructure that MUST be complete before ANY user story can be implemented

CRITICAL: No user story work can begin until this phase is complete

Checkpoint: Foundation ready β€” user story implementation can now begin


Phase 3: User Story 1 β€” Package a Provisioned Cluster as Reusable Boxes (Priority: P1) MVP

Goal: Create demo-bake.sh that packages all 4 running VMs into .box files with manifest tracking and 2-set rotation.

Independent Test: Run demo-setup.sh (from scratch), then demo-bake.sh, verify 4 .box files exist in demo/vagrant/boxes/ and manifest.json is valid. Run demo-bake.sh --list and confirm output. Run demo-bake.sh --delete <label> and confirm cleanup.

Implementation for User Story 1

Checkpoint: demo-bake.sh is fully functional. Can package, list, and delete box sets. make demo-bake works.


Phase 4: User Story 2 β€” Boot a Demo Cluster from Pre-Baked Boxes (Priority: P1)

Goal: Modify demo-setup.sh to detect baked boxes, offer to use them (skipping provisioning), run post-restore playbook, create baseline snapshot, and prompt to bake after fresh provisions.

Independent Test: With baked boxes present, run demo-setup.sh, accept baked boot, verify all services operational and demo scenario A passes. With no boxes, verify normal provisioning flow is unchanged.

Depends on: User Story 1 (T006-T012) β€” baked boxes must exist to test boot

Implementation for User Story 2

Checkpoint: Full bake-then-boot cycle works. Boot from baked boxes in < 5 min. Demo scenario A passes against baked-boot cluster. Fresh provision flow unchanged.


Phase 5: User Story 3 β€” Rebuild Baked Boxes from Current Codebase (Priority: P2)

Goal: Create demo-refresh.sh for single-command destroy-provision-bake cycle.

Independent Test: Run demo-refresh.sh, verify VMs are destroyed, reprovisioned, baked, and new manifest reflects current commit.

Depends on: User Story 1 (bake functionality), User Story 2 (boot from baked)

Implementation for User Story 3

Checkpoint: demo-refresh.sh completes full destroy-provision-bake cycle. make demo-refresh works. Previous boxes preserved on failure.


Phase 6: User Story 4 β€” Override Baked Box Behavior via Environment Variable (Priority: P3)

Goal: Ensure DEMO_USE_BAKED env var provides deterministic non-interactive control.

Independent Test: Run with DEMO_USE_BAKED=1 (boxes present β†’ boots silently; no boxes β†’ error). Run with DEMO_USE_BAKED=0 (boxes present β†’ provisions from scratch silently, no auto-bake prompt).

Depends on: User Story 2 (prompt logic already in place)

Implementation for User Story 4

Checkpoint: DEMO_USE_BAKED=1 ./demo/scripts/demo-setup.sh and DEMO_USE_BAKED=0 ./demo/scripts/demo-setup.sh both behave deterministically without prompts.


Phase 7: Polish & Cross-Cutting Concerns

Purpose: Documentation, compatibility validation, edge case handling


Dependencies & Execution Order

Phase Dependencies

User Story Dependencies

Parallel Opportunities


Parallel Example: User Story 1

# After Foundational phase complete:

# Sequential (core packaging must be built first):
Task T006: "Create demo-bake.sh argument parsing"
Task T007: "Implement verify_cluster_running()"
Task T008: "Implement package_vm() with provider branching"
Task T009: "Implement bake_all() with rotation"

# Then in parallel (independent operations on same file, different functions):
Task T010: "Implement list_sets()"      # reads manifest only
Task T011: "Implement delete operations" # deletes from manifest

# Then:
Task T012: "Add interrupt/cleanup handler"

Implementation Strategy

MVP First (User Story 1 Only)

  1. Complete Phase 1: Setup (T001-T003)
  2. Complete Phase 2: Foundational (T004-T005)
  3. Complete Phase 3: User Story 1 (T006-T012)
  4. STOP and VALIDATE: Bake a cluster, verify 4 .box files and valid manifest
  5. This alone delivers value: boxes are ready for manual use even before US2

Incremental Delivery

  1. Setup + Foundational β†’ Infrastructure ready
  2. User Story 1 β†’ Can bake boxes β†’ Validate independently
  3. User Story 2 β†’ Can boot from baked boxes in < 5 min β†’ Validate independently
  4. User Story 3 β†’ Single-command refresh cycle β†’ Validate independently
  5. User Story 4 β†’ CI/automation support β†’ Validate independently
  6. Polish β†’ Documentation and compatibility validation

Notes